import type { RouteRecordRaw } from "vue-router";

// 定义常量路由：全部用户都可以访问到的路由
export const staticRouter: RouteRecordRaw[] = [
  {
    path: "/",
    name: "index",
    redirect: "/home",
    component: () => import("@/views/home/home.vue"),
    children: []
  },
  {
    path: "/home",
    name: "home",
    component: () => import("@/views/home/home.vue")
  },
  {
    path: "/login",
    name: "login",
    component: () => import("@/views/login/login.vue")
  },
  {
    path: "/404",
    name: "404",
    component: () => import("@/views/404/404.vue")
  },
  {
    path: "/:pathMatch(.*)*",
    name: "Any",
    redirect: "/404"
  }
];
